package com.dbn.webmagic.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.dbn.webmagic.dao.AuthorizeDao;
import com.dbn.webmagic.dao.LincenseDao;
import com.dbn.webmagic.entity.Authorize;
import com.dbn.webmagic.entity.Comnotice;
import com.dbn.webmagic.service.AuthorizeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

@Service("authorizeService")
public class AuthorizeServiceImpl extends ServiceImpl<AuthorizeDao, Authorize> implements AuthorizeService {
    @Autowired
    private AuthorizeDao authorizeDao;

    @Override
    public List<Authorize> selectbyparam(String judgementNo, String varietyName, String applyCompany,String CropID) {
        List<Authorize> list=authorizeDao.selectbyparam(judgementNo,varietyName,applyCompany,CropID);
        if(list.size()==0){
            return null;
        }
        return list;
    }

    @Override
    public int add(Authorize authorize) {
        return authorizeDao.insert(authorize);
    }

}
